home *** CD-ROM | disk | FTP | other *** search
/ Aminet 7 / Aminet 7 - August 1995.iso / Aminet / docs / misc / ConcNews.lha / news / amiga.compilers / comp.sys.amiga.programmer_10499_000032.msg next >
Encoding:
Text File  |  1994-11-27  |  1.9 KB  |  45 lines

  1. Newsgroups: comp.sys.amiga.programmer
  2. Path: dd.chalmers.se!news.chalmers.se!sunic!pipex!howland.reston.ans.net!gatech!concert!sas!mozart.unx.sas.com!walker
  3. From: walker@twix.unx.sas.com (Doug Walker)
  4. Subject: Re: XCEXIT, please explain (was: SAS/C 6.50 bug/feature ?)
  5. Originator: walker@twix.unx.sas.com
  6. Sender: news@unx.sas.com (Noter of Newsworthy Events)
  7. Message-ID: <CpJDFq.CF7@unx.sas.com>
  8. Date: Mon, 9 May 1994 12:59:49 GMT
  9. References: <1994May1.070050.19084@philips.oz.au> <zp6177a8UgO3Z1@da23.darkness.gun.de>
  10. Nntp-Posting-Host: twix.unx.sas.com
  11. Organization: SAS Institute Inc.
  12. Lines: 32
  13.  
  14.  
  15. In article <zp6177a8UgO3Z1@da23.darkness.gun.de>, zodiac@darkness.gun.de (Ralph Seichter) writes:
  16. |> the  NoStackCheck option. It uses ANSI-C file I/O (fread, fwrite, etc.) and
  17. |> I  guess that at least one of these functions refers to _XCEXIT. As I don't
  18. |> want any startup code, I use my own replacement function:
  19. |> 
  20. |>    VOID __stdargs _XCEXIT (LONG dummy) { return; }
  21. |> 
  22. |> This  is  almost certainly no wise behaviour, but maybe someone can tell me
  23. |> what else to do if I need to use "lib:sc.lib" without "lib:c.o".
  24.  
  25. ANSI I/O checks for CTRL-C, and the CTRL-C processing code calls
  26. exit(), which calls _XCEXIT() eventually.  You need to disable CTRL-C 
  27. checking if you don't want to have this reference.  Do it by adding
  28. this function to your code somewhere:
  29.  
  30.    void __regargs __chkabort(void){}
  31.  
  32. The __regargs is important; what you are doing is replacing the
  33. library version of __chkabort() with your own.  The library code
  34. in the ANSI I/O functions calls the regargs version of __chkabort(),
  35. not the stdargs version, so if you define a stdargs version, it won't
  36. work.
  37.  
  38. -- 
  39.   *****                    / walker@unx.sas.com
  40.  *|_o_o|\\     Doug Walker<  BIX, Portal: djwalker
  41.  *|. o.| ||                \ CompuServe: 71165,2274
  42.   | o  |//     
  43.   ====== 
  44. Any opinions expressed are mine, not those of SAS Institute, Inc.
  45.